<!DOCTYPE html>
<html lang="zh-CN" xmlns:th="http://www.thymeleaf.org">

<div th:replace="include/header::head"></div>

<div th:replace="include/teacher_navbar::navbar(${loginTeacher})"></div>

<div class="container">
	<h1>
		<img th:src="@{/static/img/exam-teacher.png}" /> 上机考试管理
	</h1>

	<form th:if="${application.exam != null}" class="exam-form form-inline" th:action="@{/teacher/manage/notify/add}" method="post">
		<h4>新增通知消息</h4>
		<input type="text" name="notice" placeholder="通知消息内容" />
		<button type="submit" class="btn btn-primary"><i class="icon-plus"></i> 添加</button>
	</form>

	<div th:if="${application.exam != null}" class="container-fluid">
		<div class="row-fluid">
			<h4>已有通知消息</h4>
			<table class="table table-striped table-bordered">
				<thead>
				<tr>
					<th class="span7">通知内容</th>
					<th class="span1">&nbsp;</th>
				</tr>
				</thead>
				<tbody>
				<tr th:each="notice, s : ${noticeList}">
					<td th:text="${notice}"></td>
					<td>
						<a class="btn" th:href="@{'/teacher/manage/notify/del/' + ${s.index}}">
							<i class="icon-remove"></i> 删除
						</a>
					</td>
				</tr>
				</tbody>
			</table>
		</div>
	</div>

	<div th:if="${application.exam == null}" class="container-fluid">
		<div class="row-fluid">
			<div  class="span12 exam-info">
				<h4><strong>没有考试正在进行~</strong></h4>
			</div>
		</div>
	</div>

</div>

<div th:replace="include/teacher_footer::footer"></div>

